package com.zhh.service.impl;

import com.zhh.common.exception.CustomException;
import com.zhh.dao.ShiroFilterDao;
import com.zhh.pojo.TbShiroFilter;
import com.zhh.service.SystemService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author
 */
@Service
public class SystemServiceImpl implements SystemService {

    @Autowired
    private ShiroFilterDao shiroFilterDao;

    @Override
    public List<TbShiroFilter> getShiroFilter() {

        List<TbShiroFilter> list=shiroFilterDao.findAll();
        if(list==null){
            throw new CustomException("获取shiro过滤链失败");
        }
        return list;
    }

}
